<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2016/7/21
  Time: 10:51
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page import="com.lovcreate.bean.User" %>
<html>
<head>
    <title>Login Success</title>
</head>
<body>
    <a href="QueryServlet">query</a>
    <%
        User user = (User)session.getAttribute("user");
        if(null == user) {
            response.sendRedirect("login.jsp");
            return ;
        }
        if("2".equals(((User)session.getAttribute("user")).getAuthority())) {
    %>
    <a href="UpdateServlet">update</a>
    <%}%>
</body>
</html>

